package bgu.eliav;

import java.io.IOException;
import java.io.Serializable;
import java.lang.ref.PhantomReference;

import android.R.integer;
import android.R.string;
import android.os.Parcel;
import android.os.Parcelable;

public class User implements Parcelable {

	/**
	 * 
	 */
	private static final long serialVersionUID = 6128651542778552097L;
	private String name;
	private String id;
	private String phoneNum;
	private String address;
	private String bDate;

	public User(String name, String id, String phoneNum, String address,
			String bdate) {
		this.name = name;
		this.id = id;
		this.phoneNum = phoneNum;
		this.address = address;
		this.bDate = bdate;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public String getId() {
		return id;
	}

	public void setId(String id) {
		this.id = id;
	}

	public String getPhoneNum() {
		return phoneNum;
	}

	public void setPhoneNum(String phoneNum) {
		this.phoneNum = phoneNum;
	}

	public String getAddress() {
		return address;
	}

	public void setAddress(String address) {
		this.address = address;
	}

	public String getbDate() {
		return bDate;
	}

	public void setbDate(String bDate) {
		this.bDate = bDate;
	}

	public int describeContents() {
		// TODO Auto-generated method stub
		return 0;
	}

	public void writeToParcel(Parcel dest, int flags) {
		dest.writeString(name);
		dest.writeString(id);
		dest.writeString(phoneNum);
		dest.writeString(address);
		dest.writeString(bDate);
	}

	public static final Parcelable.Creator<User> CREATOR = new Parcelable.Creator<User>() {
		public User createFromParcel(Parcel in) {
			return new User(in);
		}

		public User[] newArray(int size) {
			return new User[size];
		}
	};

	private User(Parcel in) {
		name = in.readString();
		id=in.readString();
		phoneNum=in.readString();
		address=in.readString();
		bDate=in.readString();
		
	}
}
